-
Notifications
You must be signed in to change notification settings - Fork 117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update required PHP and platform PHP. #1088
Conversation
Part of the motivation here is to resolve a class of CI errors that are blocking various tests. |
Given that WordPress itself requires a minimum of PHP 7.2, could we bump these numbers further up? |
Er, our support policy here is WP - 2, right? WordPress supported PHP 7.0 until 6.6, so I guess if we want to peg to WP's minimum requirements, we can't bump past 7.0 quite yet. |
@@ -20,7 +20,7 @@ | |||
"dealerdirect/phpcodesniffer-composer-installer": true | |||
}, | |||
"platform": { | |||
"php": "5.6" | |||
"php": "7.1" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why would this not be the same value as require
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To satisfy the constraints of our current PHPUnit requirement (PHPUnit 7.5.20 asks for PHP 7.1+). In CI this isn't an issue, because if we are in a part of the test matrix specifying PHP 7.0 then we detect that and install PHPUnit 5.7 instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can possibly get a better sense of what's happening if you checkout the current trunk branch, remove the Composer lock file, and run composer i
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, I see!
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Root composer.json requires woocommerce/woocommerce-sniffs 0.1.0 -> satisfiable by woocommerce/woocommerce-sniffs[0.1.0].
- woocommerce/woocommerce-sniffs 0.1.0 requires php >=7.0 -> your php version (5.6; overridden via config.platform, actual: 8.3.9) does not satisfy that requirement.
Problem 2
- phpunit/phpunit[7.5.0, ..., 7.5.20] require php ^7.1 -> your php version (5.6; overridden via config.platform, actual: 8.3.9) does not satisfy that requirement.
- Root composer.json requires phpunit/phpunit ^7.5 -> satisfiable by phpunit/phpunit[7.5.0, ..., 7.5.20].
Yep, L-2, so we generally need to match WP 6.4 in terms of minimum supported PHP. |
composer.json
and the currently committedcomposer.lock
are out of sync.